package com.lhl.gencode.autoconfigure;

import com.lhl.gencode.auditing.JpaAuditingHandlerRegistrar;
import io.swagger.annotations.Api;
import lombok.extern.slf4j.Slf4j;
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.Import;
import org.springframework.data.jpa.repository.config.EnableJpaAuditing;
import org.springframework.data.redis.core.StringRedisTemplate;

import javax.annotation.PostConstruct;

/**
 * @className: com.lhl.gencode.autoconfigure.GenCodeConfiguration
 * @description: TODO 类描述
 * @author: king
 * @date: 2021-01-12 15:02
 **/
@Api(tags = "GenCodeConfiguration", produces = "GenCodeConfiguration")
@Slf4j
@Configuration
@ConditionalOnClass(StringRedisTemplate.class)
@Import(JpaAuditingHandlerRegistrar.class)
@EnableJpaAuditing
public class GenCodeConfiguration {

    @PostConstruct
    public void init(){
        log.debug("----------GenCode启动-----------------");
    }
}
